/***
 * 路由
 */
// configs/  routes.ts
export default [
  {
    name: '首页',
    path: '/',
    component: 'index',
  },
  {
    path: '/user',
    hideInMenu: true,
    headerRender: false,
    routes: [
      {
        name: '用户登录',
        path: '/user/login',
        component: 'user/login',
      },
      {
        name: '注册',
        path: '/user/register',
        component: 'user/register',
      },
    ],
  },
  {
    path: '/information',
    flatMenu: true,
    name: '个人简介',
    component: 'user/information',
  },
  {
    path: '/team',
    flatMenu: true,
    routes: [
      {
        name: '创建队伍',
        path: '/team/add',
        component: 'team/add',
      },
      {
        name: '队伍信息',
        path: '/team/list',
        component: 'team/list',
      },
    ],
  },
  {
    path: '/admin',
    access: 'canAdmin',
    name: '管理',
    flatMenu: true,
    routes: [
      {
        name: '用户管理',
        path: '/admin/user',
        component: 'admin/user',
      },
      {
        name: '队伍管理',
        path: '/admin/team',
        component: 'admin/team',
      },
      {
        name: '队伍修改审核',
        path: '/admin/apply/team',
        component: 'admin/apply/team',
      },
      {
        name: '搜索词管理',
        path: '/admin/search',
        component: 'admin/search',
      },
    ],
  },
];
